#include "vtor_shell.h"

#ifdef __VTOR_SHELL_SIM_VS__


int VtorShell_Device(int cmd)
{
	// 工程信息
	VtorShell_PrintString("__VTOR_SHELL_SIM_VS__\r\n");
	VtorShell_PrintString("build time "__DATE__" "__TIME__"\r\n\r\n");
	
	// 版本信息
	VtorShell_PrintString("20250403 create vtor_shell_sim_vs\r\n");
	VtorShell_PrintString("\r\n");
	
	// 运行时长（ms）
	return 0;
}

//系统复位  所有电路都会复位
void McuSystemReset(void)
{
	VtorShell_PrintString("执行复位命令。\r\n");
}

int VtorShell_Add2(int a, int b)
{
	return a + b;
}

VtorShell VtorShell_demoArray[] =
{
	(VtorShellFun)VtorShell_Icon, "icon",
	(VtorShellFun)VtorShell_Help, "help",
	(VtorShellFun)VtorShell_Void, "void",
	(VtorShellFun)VtorShell_List, "list",
	(VtorShellFun)VtorShell_Int, "int",
	(VtorShellFun)VtorShell_String, "str",
	(VtorShellFun)VtorShell_HexString, "hexstr",
	(VtorShellFun)VtorShell_Call, "call",
	(VtorShellFun)VtorShell_Memory, "mem",
	(VtorShellFun)VtorShell_ReadInt32, "readint32",
	(VtorShellFun)VtorShell_WriteInt32, "writeint32",
	(VtorShellFun)VtorShell_ReadMem, "readmem",
	(VtorShellFun)VtorShell_WriteMem, "writemem",
	
	(VtorShellFun)VtorShell_Device, "dev",
	(VtorShellFun)McuSystemReset, "reset",
	
	
	
	(VtorShellFun)VtorShell_Add2, "add2",
	(VtorShellFun)VtorShell_Void, "void",
	(VtorShellFun)VtorShell_Void, "void",
	(VtorShellFun)VtorShell_Void, "void",
	(VtorShellFun)VtorShell_Void, "void",
	(VtorShellFun)VtorShell_Void, "void",
	(VtorShellFun)VtorShell_Void, "void",
	(VtorShellFun)VtorShell_Void, "void",
	(VtorShellFun)NULL, "",

};



void VtorShell_Init()
{
	VtorShell_shellHeader = (VtorShell*)VtorShell_demoArray;
}


int32_t VtorShell_PrintString(uint8_t* str)
{
	return VtorString_ChanPrintString(5, str);
}


#endif


